﻿/* $RCSFile: CreateInterview.asmx.cs $
 * Copyright (C) Addon Nice Technologies 2010
 * $Source: ?/Addon Nice/AddonNice/AddonNice.LeadProspection/Services/CreateInterview.asmx.cs $
 * $log$
 * Revision 24 2010/08/10 17:59:16  christian.surieux
 *   Missing comment in asmx file
 * Revision 11 2010/08/09 10:18:24  christian.surieux
 *   Added Log comment to all cs files
 */

using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using System.Web.Services;
using AddonNice.CRMWrapper;

namespace AddonNice.LeadProspection.Services
{
    /// <summary>
    /// Summary description for CreateInterview
    /// </summary>
    [WebService(Namespace = "http://tempuri.org/")]
    [WebServiceBinding(ConformsTo = WsiProfiles.BasicProfile1_1)]
    [System.ComponentModel.ToolboxItem(false)]
    // To allow this Web Service to be called from script, using ASP.NET AJAX, uncomment the following line. 
    [System.Web.Script.Services.ScriptService]
    public class CreateInterview : System.Web.Services.WebService
    {
        CRMWrapperBase Wrapper
        {
            get
            {
                return AddonNice.Security.PortalSecurity.Wrapper;
            }
        }
    

        [WebMethod]
        public Guid Create(string subject,Guid contactid,Guid campaignid)
        {
            ADNDynInterview dynI    =   new ADNDynInterview(Wrapper,subject);
            dynI.contactid      =   contactid;
            //dynI.campaignid     =   campaignid;
            dynI.Create();
            return dynI.interviewid;
        }
    }
}
